package com.xbb.mapper;

import com.xbb.entity.Role;
import com.xbb.entity.Userroles;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author Mr xie
 * @since 2020-05-19
 */
public interface UserrolesMapper extends BaseMapper<Userroles> {

    //显示指定用户的所有角色---uid
    public List<Role> getRolesByUserId(Integer uid);

    //给指定用户批量移除角色
    public boolean delRolesByUserId(@Param("uid") Integer uid, @Param("rids") String[] rids);
}
